pull: Use all available commits for delta sources
authorColin Walters <walters@verbum.org>
Fri, 24 Feb 2017 02:49:21 +0000 (21:49 -0500)
committerAtomic Bot <atomic-devel@projectatomic.io>
Sat, 4 Mar 2017 10:11:14 +0000 (10:11 +0000)
commita787e0c072756863136e1951ce3a99012bda40d2
tree970a0fea4c9fc5aaa0bfa13e0f94fb26ba21573b
parentb41f150a722ded3914a38b2f8a123d1aca7f8260
pull: Use all available commits for delta sources

The previous logic for static deltas was to use as a FROM
revision the current branch tip.  However, we want
to support deltas between branches in an automatic
fashion.

If a summary file is available, we already have an
enumerated list of deltas - so the logic introduced
here is to search it, and find the newest commit
we have locally that matches the TO revision target.

This builds on some thoughts from
https://github.com/ostreedev/ostree/pull/151#issuecomment-232390232

Closes: https://github.com/ostreedev/ostree/pull/151
Closes: #710
Approved by: giuseppe
src/libostree/ostree-repo-pull.c
tests/test-delta.sh